package org.mx.graphql.bean;

import org.mx.RandomUtils;

@SuppressWarnings("javadoc")
public class EventInfo {
    private String id, name, address, category, content;
    private Long happenTime = System.currentTimeMillis() + RandomUtils.randomInt(1000, 1000 * 500);
    private Integer level = RandomUtils.randomInt(1, 5);
    private Person person;
    private EventState state = EventState.values()[RandomUtils.randomInt(0, 3)];
    private Boolean valid = RandomUtils.randomInt(1, 2) % 2 == 0;

    public enum EventState {
        S1, S2, S3, S4
    }

    public EventInfo() {
        super();
    }

    public EventInfo(int index, String category, Person person) {
        this();
        this.id = "" + index;
        this.name = "name " + index;
        this.address = "address " + index;
        this.category = category;
        this.content = "content " + index;
        this.person = person;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getAddress() {
        return address;
    }

    public void setAddress(String address) {
        this.address = address;
    }

    public String getCategory() {
        return category;
    }

    public void setCategory(String category) {
        this.category = category;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public Long getHappenTime() {
        return happenTime;
    }

    public void setHappenTime(Long happenTime) {
        this.happenTime = happenTime;
    }

    public Integer getLevel() {
        return level;
    }

    public void setLevel(Integer level) {
        this.level = level;
    }

    public Person getPerson() {
        return person;
    }

    public void setPerson(Person person) {
        this.person = person;
    }

    public EventState getState() {
        return state;
    }

    public void setState(EventState state) {
        this.state = state;
    }

    public Boolean getValid() {
        return valid;
    }

    public void setValid(Boolean valid) {
        this.valid = valid;
    }
}
